<?php
namespace ClubAPP\Controller;
use Think\Controller;
class CourseController extends Controller {
    public function courselist(){
        $coursemodel = M('course');
        $course = $coursemodel->select();      
        echo json_encode($course);
    }
    public function coursedetail($course_id){
     $coursemodel = M('course');
     $course=$coursemodel->where("course_id=$course_id")->find();
     echo json_encode($course);
    }
}
?>